<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.org/ui">

    <h:head>
        <title>#{title}</title>
        <link rel="stylesheet" type="text/css"
              href="#{resource['css:template.css']}" />
    </h:head>
    <h:body >
        <div class="header">
            <ui:insert name="header" >
                <h:form >
                    <p:toolbar style="min-height: 50px" >
                        <p:toolbarGroup align="left" >

                            <p:graphicImage value="/resources/logo.png" height="50px"/> 
                        </p:toolbarGroup>
                        <p:toolbarGroup align="right" >
                            <h:panelGrid columns="2" width="200px">
                                <p:commandButton value="Login" action="/login?faces-redirect=true" icon="ui-icon-document" />
                                <p:commandLink value="Register" action="/register"/>
                            </h:panelGrid>
                        </p:toolbarGroup>
                    </p:toolbar>
                </h:form>
            </ui:insert>
        </div>
        <div class="content">
            <div class="menu">
                <ui:insert name="menu" >
                    <h:form >
                        <p:menu style="min-width: 100%; min-height: 100%" header="Menu">  
                            <p:submenu label="Menu" style="min-width: 210px" rendered="true">  
                                <p:menuitem     rendered="#{utilLogin.connected}" action="/pages/caracteristique/List" value="Show All Caracteristique"/>  
                                <p:menuitem     rendered="#{utilLogin.connected}" action="/pages/commandeclient/List" value="Show All Commandeclient"/>  
                                <p:menuitem     rendered="#{utilLogin.connected}" action="/pages/commandefour/List" value="Show All Commandefour   "/>  
                                <p:menuitem     rendered="#{utilLogin.connected}" action="/pages/fournisseur/List" value="Show All Fournisseur   "/>  
                                <p:menuitem     rendered="#{utilLogin.connected}" action="/pages/item/List" value="Show All Item   "/>  
                                <p:menuitem     rendered="#{utilLogin.connected}" action="/pages/itemFour/List" value="Show All ItemFour   "/>  
                                <p:menuitem     rendered="#{utilLogin.connected}" action="/pages/photos/List" value="Show All Photos   "/>  
                                <p:menuitem     rendered="#{utilLogin.connected}" action="/pages/prix/List" value="Show All Prix   "/>  
                                <p:menuitem     rendered="#{utilLogin.connected}" action="/pages/utilisateur/List" value="Show All Utilisateur   "/>  

                            </p:submenu>
                        </p:menu>
                    </h:form>
                </ui:insert>
            </div>
            <div class="contentBody">
                <ui:insert name="content" />
            </div>
            <div style="clear: both;" />
        </div>
        <div class="footer">
            <ui:insert name="footer" >
                <h:form >
                    <p:panel>
                        This work was performed by the King
                    </p:panel>
                </h:form>
            </ui:insert>
        </div>
    </h:body>
</html>